#define ElemType int

typedef struct ListNode List_Node;

#include "common.h"

int findCircleNum(int** isConnected, int isConnectedSize, int* isConnectedColSize);

void dfs(int** isConnected, char* visited, int provinces, int i);

int main()
{
	return 0;
}

int findCircleNum(int** isConnected, int isConnectedSize, int* isConnectedColSize)
{
	char* visited = calloc(isConnectedSize, sizeof(char));
	int res = 0;
	for (int i = 0; i < isConnectedSize; i++)
		if (!visited[i]) {
			dfs(isConnected, visited, isConnectedSize, i);
			res++;
		}
	return res;
}

void dfs(int** isConnected, char* visited, int provinces, int idx)
{
	for (int i = 0; i < provinces; i++)
		if (isConnected[idx][i] && !visited[i]) {
			visited[i] = 1;
			dfs(isConnected, visited, provinces, i);
		}
}
